<?php

namespace app\service;

use app\traits\Singleton;

class PasswordMixService
{
    use Singleton;
    public function mixSalt($password, $newSalt = '')
    {
        if (empty($newSalt)) {
            $newSalt = uniqid();
        }

        return [
            'salt' => $newSalt,
            'pass' => md5($newSalt . $password)
        ];
    }
}